package com.qfedu.yuxiaoer.controller;

import com.qfedu.yuxiaoer.entity.TenantContract;
import com.qfedu.yuxiaoer.service.TenantContractService;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

/**
 * @author cxh
 * @version 1.0
 * @date 2023/2/15 19:12
 */
@Api(tags = "TenantContractController", description = "租客合同")
@RestController
@RequestMapping("/tenantContract")
public class TenantContractController {
    @Autowired
    private TenantContractService tenantContractService;

    @ApiOperation(value = "查询所有租客合同")
    @RequestMapping(value = "/findAll",method = RequestMethod.GET)
    public List<TenantContract> findAllTenantContract(){
        return tenantContractService.findAllTenantContract();
    }
}
